-------------------------------------------------------------------------------
Sample Name: Eval

Description: A class that evaluates an expression stored in a string. VB.NET 
             still lacks of a similar function, so it can be useful to .NET 
             developers too.

Download URL: http://www.Planet-Source-Code.com/vb/scripts/ShowCode.asp?txtCodeId=4896&lngWId=1
-------------------------------------------------------------------------------

IMPORTANT NOTE
The first step to ensure that you can migrate the VB6 project to VB.NET is 
loading the original project in the Visual Basic 6 IDE, run it to ensure that 
it works fine, that all the required type libraries are installed, and that all 
file paths are correct. 
Regardless of whether you edited the source code in any way, you should save 
the VB6 project: this save operation ensures that the .vbp file includes  
the correct path and version of referenced type libraries. 
After saving the project, it's usually a good idea to compile the VB6 project
to an executable, to detect any VB6 compilation errors that would appear under 
VB.NET as well. 
(If you don't recompile the project VB Migration Partner will display a warning 
when you later load the project.)


This sample needs two AddDataFile pragmas, whose purpose is copying two data files
into the VB.NET solution's folder. You can insert them at the top of the frmEval 
form:

'## AddDataFile pff.Wav
'## AddDataFile flip.wav




VB Migration Partner typically delivers many warnings that are related to 
code analysis as well as suggestions about how you can improve the original 
VB6 code before converting it to VB.NET. 
You can suppress these warnings by adding the following project-level pragmas 
at the top of any of the file that make up the project:

'## project:DisableMessages CodeAnalysis
'## project:DisableMessage 0354
'## project:DisableMessage 0364